<template>
	<!--当前界面为uni扩展navbar-->
	<view class="comp-base-section-box">
		<uni-card margin="0px" padding="0px" spacing="0px" :is-full="true" :is-shadow="false" :border="false">
			<view slot="title" class="section-title">
				<uni-list :border="false">
					<uni-list-item :title="title" :rightText="showMore ? '更多' : ''"
						:extraIcon="extraIconObj" :border="false"
						:showArrow="showMore" :showExtraIcon="true">
					</uni-list-item>
				</uni-list>
			</view>
		</uni-card>
		<slot></slot>
	</view>
</template>

<script>
	export default {
		name: "c-base-section",
		props: {
			title: {
				type: String,
				default: ""
			},
			iconType: {
				type: String,
				default: ""
			},
			iconSize: {
				type: Number,
				default: 18
			},
			iconColor: {
				type: String,
				default: ""
			},
			showMore: {
				type: Boolean,
				default: true
			}
		},
		data() {
			return {
				
			}
		},
		computed: {
			extraIconObj() {
				return {
					type: this.iconType || "list",
					size: this.iconSize || 18,
					color: this.iconColor || "#1cbbb4"
				}
			}
		},
		mounted() {
			
		},
		methods: {
			
		}
	}
</script>

<style scoped lang="scss">
	.comp-base-section-box {
		/deep/ .section-title {
			.uni-list-item__content-title {
				font-size: 15px;
			}
		}
	}
</style>
